package com.zjj.day2.Test6;
/**
 * @author zhoujunjie
 * @desc TODO
 * @date 2025/4/20
 */
class Goods {
    private String name;
    private double price;

    public Goods(String name, double price) {
        this.name = name;
        this.price = price;
    }

    public String getName() {
        return name;
    }

    public double getPrice() {
        return price;
    }

    @Override
    public String toString() {
        return "商品名称: " + name + ", 价格: " + price;
    }
}